package com.zzw.hj38;

import java.util.Scanner;

/**
 * @Project: hw_java
 * @Description: 求小球落地5次后所经历的路程和第5次反弹的高度
 * @Author: zzw
 */
// 注意类名必须为 Main, 不要有任何 package xxx 信息
public class Main {
    public static void main(String[] args) {
        Scanner in = new Scanner(System.in);
        float h = in.nextFloat();
        float s = 0;
        for (int i = 0; i < 5; i++) {
            s += (i == 0 ? h : 2 * h);
            h /= 2;
        }
        System.out.println(s);
        System.out.println(h);
    }
}